import java.util.Arrays;

public class Test {

    public static void main(String[] args) {
        int[][] array = new int[2][];//不规则数组
        array[0] = new int[3];
        array[1] = new int[5];
        System.out.println(Arrays.deepToString(array));
        //System.out.println(Arrays.toString(array));
    }

    public static void main1(String[] args) {
        int[][] array = {{1,2,3},{4,5,6}};
        int[][] array2 = new int[2][3];
        int[][] array3 = new int[][] {{1,2,3},{4,5,6}};

        for (int i = 0; i < array.length; i++) {
            for (int j = 0; j < array[i].length; j++) {
                System.out.print(array[i][j]+" ");
            }
            System.out.println();
        }
        System.out.println("========================");
        for (int[] tmp:array) {
            for (int x:tmp) {
                System.out.print(x+" ");
            }
            System.out.println();
        }
        System.out.println("========================");
        System.out.println(Arrays.deepToString(array));
    }

}
